<template>
  <el-col class="form-item" :span="span" :md="span?span:md" :sm="span?span:sm" :xs="span?span:xs" >
    <el-form-item :size="size" :label="label" :prop="prop">
      <slot></slot>
    </el-form-item>
  </el-col>
</template>

<script>
  export default {
    name: 'FormItem',

    props: {
      span: {
        type: Number,
        default: undefined,
      },
      xs: {
        type: Number,
        default: 12
      },
      sm: {
        type: Number,
        default: 8
      },
      md: {
        type: Number,
        default: 6
      },
      label: {
        type: String,
        default: 'label'
      },
      prop: {
        type: String,
        default: ''
      },
      size: {
        type: String,
        default: 'small'
      }
    },
    data() {
      return {
        form: {}
      }
    },

    methods: {

    }
  }
</script>

<style lang="scss" scoped>
  .form-item {
    /deep/label {
      font-weight: normal;
    }
  }
</style>
